export const EVENT_CODE_TO_KEY_CODE = {
  // 3.1.1.1. Writing System Keys
  Backquote: "Backquote",
  Backslash: "Backslash",
  BracketLeft: "BracketLeft",
  BracketRight: "BracketRight",
  Comma: "Comma",
  Digit0: "Digit0",
  Digit1: "Digit1",
  Digit2: "Digit2",
  Digit3: "Digit3",
  Digit4: "Digit4",
  Digit5: "Digit5",
  Digit6: "Digit6",
  Digit7: "Digit7",
  Digit8: "Digit8",
  Digit9: "Digit9",
  Equal: "Equal",
  IntlBackslash: "IntlBackslash",
  IntlRo: "IntlRo",
  IntlYen: "IntlYen",
  KeyA: "KeyA",
  KeyB: "KeyB",
  KeyC: "KeyC",
  KeyD: "KeyD",
  KeyE: "KeyE",
  KeyF: "KeyF",
  KeyG: "KeyG",
  KeyH: "KeyH",
  KeyI: "KeyI",
  KeyJ: "KeyJ",
  KeyK: "KeyK",
  KeyL: "KeyL",
  KeyM: "KeyM",
  KeyN: "KeyN",
  KeyO: "KeyO",
  KeyP: "KeyP",
  KeyQ: "KeyQ",
  KeyR: "KeyR",
  KeyS: "KeyS",
  KeyT: "KeyT",
  KeyU: "KeyU",
  KeyV: "KeyV",
  KeyW: "KeyW",
  KeyX: "KeyX",
  KeyY: "KeyY",
  KeyZ: "KeyZ",
  Minus: "Minus",
  Period: "Period",
  Quote: "Quote",
  Semicolon: "Semicolon",
  Slash: "Slash",

  // 3.1.1.2. Functional Keys
  AltLeft: "AltLeft",
  AltRight: "AltRight",
  Backspace: "Backspace",
  CapsLock: "CapsLock",
  ContextMenu: "ContextMenu",
  ControlLeft: "ControlLeft",
  ControlRight: "ControlRight",
  Enter: "Enter",
  MetaLeft: "SuperLeft",
  MetaRight: "SuperRight",
  ShiftLeft: "ShiftLeft",
  ShiftRight: "ShiftRight",
  Space: "Space",
  Tab: "Tab",
  Convert: "Convert",
  KanaMode: "KanaMode",
  Lang1: "Lang1",
  Lang2: "Lang2",
  Lang3: "Lang3",
  Lang4: "Lang4",
  Lang5: "Lang5",
  NonConvert: "NonConvert",

  // 3.1.2. Control Pad Section
  Delete: "Delete",
  End: "End",
  Help: "Help",
  Home: "Home",
  Insert: "Insert",
  PageDown: "PageDown",
  PageUp: "PageUp",

  // 3.1.3. Arrow Pad Section
  ArrowDown: "ArrowDown",
  ArrowLeft: "ArrowLeft",
  ArrowRight: "ArrowRight",
  ArrowUp: "ArrowUp",

  // 3.1.4. Numpad Section
  NumLock: "NumLock",
  Numpad0: "Numpad0",
  Numpad1: "Numpad1",
  Numpad2: "Numpad2",
  Numpad3: "Numpad3",
  Numpad4: "Numpad4",
  Numpad5: "Numpad5",
  Numpad6: "Numpad6",
  Numpad7: "Numpad7",
  Numpad8: "Numpad8",
  Numpad9: "Numpad9",
  NumpadAdd: "NumpadAdd",
  NumpadBackspace: "NumpadBackspace",
  NumpadClear: "NumpadClear",
  NumpadClearEntry: "NumpadClearEntry",
  NumpadComma: "NumpadComma",
  NumpadDecimal: "NumpadDecimal",
  NumpadDivide: "NumpadDivide",
  NumpadEnter: "NumpadEnter",
  NumpadEqual: "NumpadEqual",
  NumpadHash: "NumpadHash",
  NumpadMemoryAdd: "NumpadMemoryAdd",
  NumpadMemoryClear: "NumpadMemoryClear",
  NumpadMemoryRecall: "NumpadMemoryRecall",
  NumpadMemoryStore: "NumpadMemoryStore",
  NumpadMemorySubtract: "NumpadMemorySubtract",
  NumpadMultiply: "NumpadMultiply",
  NumpadParenLeft: "NumpadParenLeft",
  NumpadParenRight: "NumpadParenRight",
  NumpadStar: "NumpadStar",
  NumpadSubtract: "NumpadSubtract",

  // 3.1.5. Function Section
  Escape: "Escape",
  F1: "F1",
  F2: "F2",
  F3: "F3",
  F4: "F4",
  F5: "F5",
  F6: "F6",
  F7: "F7",
  F8: "F8",
  F9: "F9",
  F10: "F10",
  F11: "F11",
  F12: "F12",
  Fn: "Fn",
  FnLock: "FnLock",
  PrintScreen: "PrintScreen",
  ScrollLock: "ScrollLock",
  Pause: "Pause",

  // 3.1.6. Media Keys
  BrowserBack: "BrowserBack",
  BrowserFavorites: "BrowserFavorites",
  BrowserForward: "BrowserForward",
  BrowserHome: "BrowserHome",
  BrowserRefresh: "BrowserRefresh",
  BrowserSearch: "BrowserSearch",
  BrowserStop: "BrowserStop",
  Eject: "Eject",
  LaunchApp1: "LaunchApp1",
  LaunchApp2: "LaunchApp2",
  LaunchMail: "LaunchMail",
  MediaPlayPause: "MediaPlayPause",
  MediaSelect: "MediaSelect",
  MediaStop: "MediaStop",
  MediaTrackNext: "MediaTrackNext",
  MediaTrackPrevious: "MediaTrackPrevious",
  Power: "Power",
  Sleep: "Sleep",
  AudioVolumeDown: "AudioVolumeDown",
  AudioVolumeMute: "AudioVolumeMute",
  AudioVolumeUp: "AudioVolumeUp",
  WakeUp: "WakeUp",

  // 3.1.7. Legacy, Non-Standard and Special Keys
  Hyper: "Hyper",
  Super: "Meta",
  Turbo: "Turbo",
  Abort: "Abort",
  Resume: "Resume",
  Suspend: "Suspend",
  Again: "Again",
  Copy: "Copy",
  Cut: "Cut",
  Find: "Find",
  Open: "Open",
  Paste: "Paste",
  Props: "Props",
  Select: "Select",
  Undo: "Undo",
  Hiragana: "Hiragana",
  Katakana: "Katakana",
  Unidentified: "Unidentified",
};

const KEYBOARD_KEYS = [
  "Backquote",
  "Backslash",
  "BracketLeft",
  "BracketRight",
  "Comma",
  "Digit0",
  "Digit1",
  "Digit2",
  "Digit3",
  "Digit4",
  "Digit5",
  "Digit6",
  "Digit7",
  "Digit8",
  "Digit9",
  "Equal",
  "IntlBackslash",
  "IntlRo",
  "IntlYen",
  "KeyA",
  "KeyB",
  "KeyC",
  "KeyD",
  "KeyE",
  "KeyF",
  "KeyG",
  "KeyH",
  "KeyI",
  "KeyJ",
  "KeyK",
  "KeyL",
  "KeyM",
  "KeyN",
  "KeyO",
  "KeyP",
  "KeyQ",
  "KeyR",
  "KeyS",
  "KeyT",
  "KeyU",
  "KeyV",
  "KeyW",
  "KeyX",
  "KeyY",
  "KeyZ",
  "Minus",
  "Period",
  "Quote",
  "Semicolon",
  "Slash",
  "AltLeft",
  "AltRight",
  "Backspace",
  "CapsLock",
  "ContextMenu",
  "ControlLeft",
  "ControlRight",
  "Enter",
  "SuperLeft",
  "SuperRight",
  "ShiftLeft",
  "ShiftRight",
  "Space",
  "Tab",
  "Convert",
  "KanaMode",
  "Lang1",
  "Lang2",
  "Lang3",
  "Lang4",
  "Lang5",
  "NonConvert",
  "Delete",
  "End",
  "Help",
  "Home",
  "Insert",
  "PageDown",
  "PageUp",
  "ArrowDown",
  "ArrowLeft",
  "ArrowRight",
  "ArrowUp",
  "NumLock",
  "Numpad0",
  "Numpad1",
  "Numpad2",
  "Numpad3",
  "Numpad4",
  "Numpad5",
  "Numpad6",
  "Numpad7",
  "Numpad8",
  "Numpad9",
  "NumpadAdd",
  "NumpadBackspace",
  "NumpadClear",
  "NumpadClearEntry",
  "NumpadComma",
  "NumpadDecimal",
  "NumpadDivide",
  "NumpadEnter",
  "NumpadEqual",
  "NumpadHash",
  "NumpadMemoryAdd",
  "NumpadMemoryClear",
  "NumpadMemoryRecall",
  "NumpadMemoryStore",
  "NumpadMemorySubtract",
  "NumpadMultiply",
  "NumpadParenLeft",
  "NumpadParenRight",
  "NumpadStar",
  "NumpadSubtract",
  "Escape",
  "Fn",
  "FnLock",
  "PrintScreen",
  "ScrollLock",
  "Pause",
  "BrowserBack",
  "BrowserFavorites",
  "BrowserForward",
  "BrowserHome",
  "BrowserRefresh",
  "BrowserSearch",
  "BrowserStop",
  "Eject",
  "LaunchApp1",
  "LaunchApp2",
  "LaunchMail",
  "MediaPlayPause",
  "MediaSelect",
  "MediaStop",
  "MediaTrackNext",
  "MediaTrackPrevious",
  "Power",
  "Sleep",
  "AudioVolumeDown",
  "AudioVolumeMute",
  "AudioVolumeUp",
  "WakeUp",
  "Meta",
  "Hyper",
  "Turbo",
  "Abort",
  "Resume",
  "Suspend",
  "Again",
  "Copy",
  "Cut",
  "Find",
  "Open",
  "Paste",
  "Props",
  "Select",
  "Undo",
  "Hiragana",
  "Katakana",
  "F1",
  "F2",
  "F3",
  "F4",
  "F5",
  "F6",
  "F7",
  "F8",
  "F9",
  "F10",
  "F11",
  "F12",
  "F13",
  "F14",
  "F15",
  "F16",
  "F17",
  "F18",
  "F19",
  "F20",
  "F21",
  "F22",
  "F23",
  "F24",
  "F25",
  "F26",
  "F27",
  "F28",
  "F29",
  "F30",
  "F31",
  "F32",
  "F33",
  "F34",
  "F35",
];
const MOUSE_KEYS = ["M-Left", "M-Right", "M-Middle", "M-Back", "M-Forward"];
const SCROLL_KEYS = ["ScrollDown", "ScrollUp"];
const GAMEPAD_KEYS = [
  "G-South",
  "G-East",
  "G-North",
  "G-West",
  "G-C",
  "G-Z",
  "G-LeftTrigger",
  "G-LeftTrigger2",
  "G-RightTrigger",
  "G-RightTrigger2",
  "G-Select",
  "G-Start",
  "G-Mode",
  "G-LeftThumb",
  "G-RightThumb",
  "G-DPadUp",
  "G-DPadDown",
  "G-DPadLeft",
  "G-DPadRight",
];

export const KEY_NAMES = [
  ...KEYBOARD_KEYS,
  ...MOUSE_KEYS,
  ...GAMEPAD_KEYS,
  ...SCROLL_KEYS,
];

export const AXIS_NAMES = [
  "LeftStickX",
  "LeftStickY",
  "RightStickX",
  "RightStickY",
  "LeftZ",
  "RightZ",
];
